package com.dong.containerEx.factoryBean;

import com.dong.containerEx.User;
import org.springframework.beans.factory.FactoryBean;

/**
 * description
 *
 * @author Administrator 2021/08/31 10:35
 */
public class MyFactoryBean implements FactoryBean<User> {

    @Override
    public User getObject() throws Exception {
        User user = new User();
        user.setName("FactoryBean");
        return user;
    }

    @Override
    public Class<?> getObjectType() {
        return User.class;
    }

    @Override
    public boolean isSingleton() {
        return false;
    }
}
